From 346f93fc27bcd9faaf8f35f9c85aafa5dfefdc8a Mon Sep 17 00:00:00 2001 From: Wil Mahan Date: Mon, 11 Oct 2004 19:15:24 +0000 Subject: [PATCH] Oops, invalid chars in bracketed external links should be added to the link description, not the trail. --- includes/Parser.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/Parser.php b/includes/Parser.php index e5169695d5..04ac280182 100644 --- a/includes/Parser.php +++ b/includes/Parser.php @@ -942,7 +942,7 @@ class Parser # removeHTMLtags()) should not be included in # URLs, per RFC 2396. if (preg_match('/&(lt|gt);/', $url, $m2, PREG_OFFSET_CAPTURE)) { - $trail = substr($url, $m2[0][1]) . $trail; + $text = substr($url, $m2[0][1]) . ' ' . $text; $url = substr($url, 0, $m2[0][1]); } -- 2.20.1